/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package fr.cggveritas.crewintranet.jms.dao.jpacontroller;

import javax.persistence.EntityManagerFactory;
import javax.persistence.Persistence;

/**
 *
 * @author Alassane
 */
public class Emf{

    private static EntityManagerFactory instance;
    /**
     * 
     */
    private Emf() {
        
    }

    public static EntityManagerFactory getInstance() {
        if (null == instance || !instance.isOpen()) {
            instance = Persistence.createEntityManagerFactory("crewintranetjsfPU");
        }
        return instance;
    }
}
